using System;
using System.Data.Entity.ModelConfiguration;
using System.Data.Common;
using System.Data.Entity;
using System.Collections.Generic;
using System.ComponentModel.DataAnnotations;
using Dal.Entities;

namespace Dal.Mapping
{
	public class NewsMap : EntityTypeConfiguration<News>
	{
		public NewsMap()
		{
			// Primary Key
			this.HasKey(t => t.ID);

			// Properties
			// Table & Column Mappings
			this.ToTable("News");
			this.Property(t => t.ID).HasColumnName("ID");
			this.Property(t => t.KeTiJieShao).HasColumnName("KeTiJieShao");
			this.Property(t => t.ZhuYiShiXiang).HasColumnName("ZhuYiShiXiang");
			this.Property(t => t.XiaZaiQu).HasColumnName("XiaZaiQu");
			this.Property(t => t.GongGaoLan).HasColumnName("GongGaoLan");
		}
	}
}

